package org.itboys.mobile.entity.mongo.dynamic;

import org.itboys.mongodb.entity.BaseMongoEntity;
import org.mongodb.morphia.annotations.Entity;

/**
 * 作者：jiangxiong
 * 日期：2017年4月26日
 * 联系方式 ：empty90911@126.com
 * 描述：圣代_移动端（通用）_动态_评论或点赞_实体。如果属性不够，请自行填充
 */
@Entity(value="SundayDynamicOperate", noClassnameStored=true)
public class SundayDynamicOperate extends BaseMongoEntity{
    private Long dynamicId;//社区动态id
    private Integer type;//1点赞，2评论
    private Long memberId;//用户id
    private String memberName;//用户昵称
    private String memberImage;//用户昵称
    private String content;//评论内容

    public SundayDynamicOperate() {
    }

    public Long getDynamicId() {
        return dynamicId;
    }

    public void setDynamicId(Long dynamicId) {
        this.dynamicId = dynamicId;
    }

    public Integer getType() {
        return type;
    }

    public void setType(Integer type) {
        this.type = type;
    }

    public Long getMemberId() {
        return memberId;
    }

    public void setMemberId(Long memberId) {
        this.memberId = memberId;
    }

    public String getMemberName() {
        return memberName;
    }

    public void setMemberName(String memberName) {
        this.memberName = memberName;
    }

    public String getMemberImage() {
        return memberImage;
    }

    public void setMemberImage(String memberImage) {
        this.memberImage = memberImage;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }
    public String getTypeStr(){
        String typeStr= "";
        if(type==null)return typeStr;

        switch (type) {
            case 1:
                typeStr="点赞";
                break;
            case 2:
                typeStr="评论";
                break;

            default:
                break;
        }
        return typeStr;
    }
}
